import { createApp } from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import ElementPlus, {ElMessage} from 'element-plus'
import 'element-plus/dist/index.css';

import axios from 'axios'

const app = createApp(App)
app.use(router)
app.use(ElementPlus)
app.config.globalProperties.$message = ElMessage;
app.use(store)
app.config.globalProperties.$axios=axios;
app.mount('#app')



// axios拦截器
// axios.interceptors.request.use(function (config) {
//     console.log('请求参数：', config);
//     return config;
// }, error => {
//     console.log('请求错误：', error);
//     return Promise.reject(error);
// });
// axios.interceptors.response.use(function (response) {
//     console.log('返回结果：', response);
//     return response;
// }, error => {
//     console.log('返回错误：', error);
//     return Promise.reject(error);
// });